预览:这是你今天将要创造的程序示例。

  • 运行 程序,然后使用“课程指南”查看可供选择的过渡单词/短语。
  • 回答完所有问题后,查看控制台,看一看故事和动画。
  • 点击 提交 然后点击 下一步 继续。

To navigate the page using the TAB key, first press ESC to exit the code editor.

stage.set_background("houseinterior") sprite = codesters.Sprite("person1", 0, -100) # text = codesters.Text("text", x, y, "color") text = codesters.Text("One evening, I fell asleep very early." , 0, 200, "blue", 100, 200, "red") stage.wait(1) transition1 = sprite.ask("Choose a transition word from the sequence category.") text.set_text(transition1) stage.set_background("city") sprite.glide_to(-120, 10) stage.wait(1) text.set_text( "I was floating very high on a cloud above the city.") stage.wait(1) transition2 = sprite.ask("Choose a transition word from the plot pivot category.") text.set_text(transition2) sprite.glide_to(0, 250) sprite.turn_right(90) sprite.glide_to(0, -300) stage.set_background('underwater') sprite.go_to(0, 300) sprite.glide_to(0, 0) text.set_text("I was in the water and there was a turtle nearby.") stage.wait(1) turtle = codesters.Sprite("turtle2", -100, -50) text.set_text("I thought we could be friends!") stage.wait(1) transition3 = sprite.ask("Choose a transition word from the contradiction category.") text.set_text(transition3) stage.wait(1) turtle.glide_to(400, 100) stage.wait(1) text.set_text("He swam away and the water became a sandy beach.") stage.set_background('summer') sprite.turn_left(90) sprite.go_to(-50, -200) transition4 = sprite.ask("Choose a transition word from the effect/consequence category.") stage.set_background("houseinterior") text.set_text(transition4) stage.wait(1) text.set_text("I woke up and I thought about my pleasant dream. I made a turtle friend and had a beach vacation!")
  • Run Code
  • 提交作品
  • 下个活动
  • Show Console
  • Reset Code Editor
  • Codesters How To (opens in a new tab)